<%@ page language="java" contentType="text/html; charset=utf-8"
    pageEncoding="utf-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>sanke</title>
 <style type="text/css">
        table
        {
            border-collapse: collapse;
            border: none;
        }
        td,tr,th
        {
            border: solid #000 1px;
        }
    </style>
<script language="javascript">
var bit1="";
var bit2="";
var bit3="";
var bit4="";
var bit5="";
var bit6="";
var bit7="";
var bit8="";
var bit9="";
var totalBit="";
function onRadioClick(){
	for(var i=1;i<=9;i++){
		var bitObj = document.getElementsByName("bit"+i);
		for(var j=0;j<bitObj.length;j++){
			if(bitObj[j].checked){
				eval("bit"+i+"=bitObj[j].value");
				}
			}
		}
totalBit = bit1+bit2+bit3+bit4+bit5+bit6+bit7+bit8+bit9;
document.getElementById("bit9Num").value=totalBit;
}
</script>
</head>
<body>
<label>零件类型：</label>
<select>
  <option value ="A">A(回转体)</option>
  <option value ="A1">A(回转体-异形体)</option>
  <option value="B">B(非回转体)</option>
  <option value="B1">B(非回转体-钣金件)</option>
  <option value="B2">B(非回转体-结构件)</option>
</select>
<br/>
<label>图纸编号：</label>
<input name="bitMapId" value=""/>
<label>九位编码：</label>
<input readonly="readonly" name="bit9Num" id="bit9Num" value=""/>
<table style="border-collapse:collapse;border:none;">
<tr>
    <th colspan="15">主码</th>
    <th colspan="14">副码</th>
  </tr>
  <tr>
    <th colspan="3">第一位</th>
    <th colspan="3">第二位</th>
    <th colspan="3">第三位</th>
    <th colspan="3">第四位</th>
    <th colspan="3">第五位</th>
    <th colspan="3">第六位</th>
    <th colspan="3">第七位</th>
    <th colspan="4">第八位</th>
    <th colspan="4">第九位</th>
  </tr>
  <tr>
    <th colspan="3">基本类型</th>
    <th colspan="3">外表面</th>
    <th colspan="3">内表面回转加工</th>
    <th colspan="3">平面加工</th>
    <th colspan="3">辅助孔齿形加工</th>
    <th colspan="3">直径(D)[mm]</th>
    <th colspan="3">长度(L)[mm]</th>
    <th colspan="4">材料,毛坯,热处理</th>
    <th colspan="4">精度</th>
  </tr>
  <tr>
    <td rowspan="2"><input id="bit1" name="bit1" type="radio" value="1" onclick="onRadioClick();"/></td>
    <td rowspan="2"style="width:2%">1</td>
    <td rowspan="2"><img src="resources/img/A11.png"  alt=""/></td>
    <td><input id="bit2" name="bit2" type="radio" value="0" onclick="onRadioClick();"/></td>
    <td style="width:2%">0</td>
    <td><img src="resources/img/A21.png"  alt=""/></td>
    <td><input id="bit3" name="bit3"  type="radio" value="0" onclick="onRadioClick();"/></td>
    <td style="width:2%">0</td>
     <td><img src="resources/img/A31.png"  alt=""/></td>
    <td><input id="bit4" name="bit4"  type="radio" value="0" onclick="onRadioClick();"/></td>
    <td style="width:2%">0</td>
     <td><img src="resources/img/A41.png"  alt=""/></td>
    <td><input id="bit5" name="bit5"  type="radio" value="0" onclick="onRadioClick();"/></td>
    <td style="width:2%">0</td>
    <td><img src="resources/img/A51.png"  alt=""/></td>
    <td><input id="bit6" name="bit6"  type="radio" value="0" onclick="onRadioClick();"/></td>
    <td style="width:2%">0</td>
     <td><label><=30</label></td>
    <td><input id="bit7" name="bit7"  type="radio" value="0" onclick="onRadioClick();"/></td>
    <td style="width:2%">0</td>
      <td><label><=30</label></td>
    <td><input id="bit8" name="bit8"  type="radio" value="0" onclick="onRadioClick();"/></td>
    <td style="width:2%">0</td>
      <td rowspan="2" ><label>冷热轧制钢材</label></td>
    <td><label>不经热处理</label></td>
    <td><input id="bit9" name="bit9"  type="radio" value="0" onclick="onRadioClick();"/></td>
    <td style="width:2%">0</td>
     <td colspan="2"><label>低精度要求或无精度要求</label></td>
  </tr>
   <tr>
    <td><input name="bit2"  type="radio" value="1" onclick="onRadioClick();"/></td>
    <td style="width:2%">1</td>
     <td><img src="resources/img/A22.png"  alt=""/></td>
    <td rowspan="2"><input name="bit3"  type="radio" value="1" onclick="onRadioClick();"/></td>
    <td rowspan="2" style="width:2%">1</td>
     <td><img src="resources/img/A32.png"  alt=""/></td>
     <td rowspan="2"><input name="bit4"  type="radio" value="1" onclick="onRadioClick();"/></td>
    <td rowspan="2" style="width:2%">1</td>
     <td><img src="resources/img/A42.png"  alt=""/></td>
       <td><input name="bit5"  type="radio" value="1" onclick="onRadioClick();"/></td>
    <td style="width:2%">1</td>
     <td><img src="resources/img/A52.png"  alt=""/></td>
      <td><input id="bit6" name="bit6"  type="radio" value="1" onclick="onRadioClick();"/></td>
    <td style="width:2%">1</td>
     <td><label><=60</label></td>
      <td><input  name="bit7"  type="radio" value="1" onclick="onRadioClick();"/></td>
    <td style="width:2%">1</td>
     <td><label><=60</label></td>
      <td><input  name="bit8"  type="radio" value="1" onclick="onRadioClick();"/></td>
    <td style="width:2%">1</td>
     <td><label>经热处理</label></td>
      <td><input  name="bit9"  type="radio" value="1" onclick="onRadioClick();"/></td>
    <td style="width:2%">1</td>
     <td rowspan="7"><label>有精度要求</label></td>
     <td><label>2</label></td>
  </tr>
   <tr>
    <td rowspan="2"><input id="bit11" name="bit1" type="radio" value="2" onclick="onRadioClick();"/></td>
    <td rowspan="2" style="width:2%">2</td>
    <td rowspan="2"><img src="resources/img/A12.png"  alt=""/></td>
    <td rowspan="2"><input id="bit22" name="bit2"  type="radio" value="2" onclick="onRadioClick();"/></td>
    <td rowspan="2" style="width:2%">2</td>
     <td><img src="resources/img/A23.png"  alt=""/></td>
    <td><img src="resources/img/A33.png"  alt=""/></td>
    <td><img src="resources/img/A43.png"  alt=""/></td>
    <td rowspan="2"><input name="bit5"  type="radio" value="2" onclick="onRadioClick();"/></td>
    <td rowspan="2" style="width:2%">2</td>
    <td><img src="resources/img/A53.png"  alt=""/></td>
     <td><input id="bit6" name="bit6"  type="radio" value="2" onclick="onRadioClick();"/></td>
    <td style="width:2%">2</td>
     <td><label><=100</label></td>
     <td><input name="bit7"  type="radio" value="2" onclick="onRadioClick();"/></td>
    <td style="width:2%">2</td>
     <td><label><=100</label></td>
      <td><input name="bit8"  type="radio" value="2" onclick="onRadioClick();"/></td>
    <td style="width:2%">2</td>
         <td rowspan="3" ><label>铸件</label></td>
     <td><label>铸铁</label></td>
    <td><input name="bit9"  type="radio" value="2" onclick="onRadioClick();"/></td>
    <td style="width:2%">2</td>
     <td><label>3</label></td>
  </tr>
  <tr>
     
     <td><img src="resources/img/A24.png"  alt=""/></td>
      <td rowspan="2"><input id="bit3" name="bit3"  type="radio" value="2" onclick="onRadioClick();"/></td>
    <td rowspan="2" style="width:2%">2</td>
     <td><img src="resources/img/A34.png"  alt=""/></td>
      <td><input name="bit4"  type="radio" value="2" onclick="onRadioClick();"/></td>
    <td style="width:2%">2</td>
     <td><img src="resources/img/A44.png"  alt=""/></td>
    <td><img src="resources/img/A54.png"  alt=""/></td>
    <td><input id="bit6" name="bit6"  type="radio" value="3" onclick="onRadioClick();"/></td>
    <td style="width:2%">3</td>
     <td><label><=160</label></td>
     <td><input name="bit7"  type="radio" value="3" onclick="onRadioClick();"/></td>
    <td style="width:2%">3</td>
     <td><label><=160</label></td>
      <td><input name="bit8"  type="radio" value="3" onclick="onRadioClick();"/></td>
    <td style="width:2%">3</td>
     <td><label>铸钢</label></td>
      <td><input name="bit9"  type="radio" value="3" onclick="onRadioClick();"/></td>
    <td style="width:2%">3</td>
     <td><label>4</label></td>
  </tr>
  <tr>
    <td rowspan="5"><input id="bit11" name="bit1" type="radio" value="3" onclick="onRadioClick();"/></td>
    <td rowspan="5" style="width:2%">3</td>
    <td rowspan="5"><img src="resources/img/A13.png"  alt=""/></td>
    <td><input id="bit22" name="bit2"  type="radio" value="3" onclick="onRadioClick();"/></td>
    <td style="width:2%">3</td>
     <td><img src="resources/img/A25.png"  alt=""/></td>
    <td><img src="resources/img/A35.png"  alt=""/></td>
    <td rowspan="2"><input id="bit4" name="bit4"  type="radio" value="3" onclick="onRadioClick();"/></td>
    <td rowspan="2" style="width:2%">3</td>
     <td><img src="resources/img/A45.png"  alt=""/></td>
    <td><input id="bit5" name="bit5"  type="radio" value="3" onclick="onRadioClick();"/></td>
    <td style="width:2%">3</td>
     <td><label>链轮,带轮</label></td>
    <td rowspan='5'><input id="bit6" name="bit6"  type="radio" value="4" onclick="onRadioClick();"/></td>
    <td rowspan='5' style="width:2%">4</td>
     <td rowspan='5'><label>>160</label></td>
    <td rowspan='5'><input id="bit7" name="bit7"  type="radio" value="4" onclick="onRadioClick();"/></td>
    <td rowspan='5' style="width:2%">4</td>
     <td rowspan='5'><label>>160</label></td>
    <td><input id="bit8" name="bit8"  type="radio" value="4" onclick="onRadioClick();"/></td>
    
    <td style="width:2%">4</td>
     <td><label>有色金属</label></td>
    <td><input id="bit9" name="bit9"  type="radio" value="4" onclick="onRadioClick();"/></td>
    <td style="width:2%">4</td>
     <td><label>5</label></td>
  </tr>
  <tr>
   <td rowspan="4"><input id="bit22" name="bit2"  type="radio" value="6" onclick="onRadioClick();"/></td>
    <td rowspan="4" style="width:2%">6</td>
   <td rowspan="4"><label>其他</label></td>
    <td><input name="bit3"  type="radio" value="3" onclick="onRadioClick();"/></td>
    <td style="width:2%">3</td>
  <td><img src="resources/img/A36.png"  alt=""/></td>
  <td><img src="resources/img/A46.png"  alt=""/></td>
  <td rowspan="4"><input name="bit5"  type="radio" value="6" onclick="onRadioClick();"/></td>
    <td rowspan="4" style="width:2%">6</td>
   <td rowspan="4"><label>其他</label></td>
 
  <td><input id="bit8" name="bit8"  type="radio" value="5" onclick="onRadioClick();"/></td>
    <td style="width:2%">5</td>
     <td rowspan="2" ><label>锻件</label></td>
     <td><label>不经热处理</label></td>
     <td><input name="bit9"  type="radio" value="5" onclick="onRadioClick();"/></td>
    <td style="width:2%">5</td>
     <td><label>两个码的组合</label></td>
     </tr>
     
  <tr>
 
  
   <td rowspan="3"><input name="bit3"  type="radio" value="6" onclick="onRadioClick();"/></td>
    <td rowspan="3" style="width:2%">6</td>
   <td rowspan="3"><label>其他</label></td>
   
   
   <td><input name="bit4"  type="radio" value="4" onclick="onRadioClick();"/></td>
    <td style="width:2%">4</td>
   <td><img src="resources/img/A47.png"  alt=""/></td>
  
    <td><input id="bit8" name="bit8"  type="radio" value="6" onclick="onRadioClick();"/></td>
    <td style="width:2%">6</td>
     <td><label>经热处理</label></td>
     <td><input  name="bit9"  type="radio" value="6" onclick="onRadioClick();"/></td>
    <td style="width:2%">6</td>
     <td><label>三个码或超过三个码的组合</label></td>
  </tr>
  
  <tr>
  <td rowspan="2"><input name="bit4"  type="radio" value="6" onclick="onRadioClick();"/></td>
    <td rowspan="2" style="width:2%">6</td>
   <td rowspan="2"><label>其他</label></td>
   
   <td><input name="bit8"  type="radio" value="7" onclick="onRadioClick();"/></td>
    <td style="width:2%">7</td>
     <td colspan="2"><label>有色金属</label></td>
     <td><input name="bit9"  type="radio" value="7" onclick="onRadioClick();"/></td>
    <td style="width:2%">7</td>
     <td colspan="2"><label>磨消加工</label></td>
  </tr>
  <tr>
   
   <td><input name="bit8"  type="radio" value="8" onclick="onRadioClick();"/></td>
    <td style="width:2%">8</td>
     <td colspan="2"><label>非金属</label></td>
      <td><input name="bit9"  type="radio" value="8" onclick="onRadioClick();"/></td>
    <td style="width:2%">8</td>
     <td colspan="2"><label>高精度要求</label></td>
  </tr>
</table>
</body>
</html>